/*
  File: UserRangeLimitAttribute.cs
  Author: rcrxy
  CreateTime: 2025/06/30 14:38

  Description:
*/

using StudentVideo.Shared.Enums;

namespace StudentVideo.Common.Attributes;

[AttributeUsage(AttributeTargets.Class | AttributeTargets.Method | AttributeTargets.Delegate, AllowMultiple = false)]
public class UserRangeLimitAttribute(params UserRangeEnum[] allowedRoles): Attribute {
   public string UserRange { get; set; } = string.Join(",", allowedRoles.Select(r => r.ToString()));
}
